<!--<?php
if ($type=='add') {print <<<EOT
-->
<form action="$ajax_basename" method="post" name="form1" onsubmit="return false;" enctype="multipart/form-data">
<table cellspacing="0" cellpadding="0" width="500">
	<tbody>
		<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>添加内容</th></tr>

		<tr>
			<td>标题</td>
			<td>
				<input type="text" class="input input_wb" size="40" name="title" value="$default[title]" maxlength="3">
			</td>
		</tr>
		<tr>
			<td>链接地址</td>
			<td>
				<input type="text" class="input input_wb" size="40" value="$default[url]" name="url">
			</td>
		</tr>
		<tr>
			<td>图片地址</td>
			<td>
				<style type="text/css">
				.imgListA_pw{padding-bottom:10px;}
				.imgListA_pw li{float:left;width:60px;margin-right:20px; text-align:center;}
				.imgListA_pw li{border:1px solid #fff;cursor:pointer;height:60px;width:60px;}
				.imgListA_pw li:hover{border:1px solid #98ba2a;}
				.imgListA_pw .current{cursor:pointer; position:relative;}
				.imgListA_pw .current div{width:60px;height:60px;background: url(apps/stopic/image/group-current.gif) no-repeat; position:absolute;}
				</style>
				
				
				<div class="cc mb10">
					<ul id="imagetype_ul" class="list_A list_80">
                        <li><span id="imagetype_upload"><input onclick="getObj('imagetype_input_div').style.display='none';getObj('imagetype_upload_div').style.display='';" name="select_imagetype" value="1" type="radio">图片上传</span></li>
                        <li><span id="imagetype_input"><input onclick="getObj('imagetype_input_div').style.display='';getObj('imagetype_upload_div').style.display='none';" checked="checked" name="select_imagetype" value="2" type="radio">图片链接</span></li>
                    </ul>
				</div>
				<div id="imagetype_input_div" style="display:">
					<div style="background:#F7F7F7; border: 1px solid #ccc; width: 40px; height: 40px;" class="fl mr10">
						<img src="#" width="40" height="40">
					</div>
					<input id="image" name="image" value="" size="40" class="input" type="text">
				</div>
				<div id="imagetype_upload_div" style="display:none;">
                     <p><input id="uploadpic" name="uploadpic" onchange="checkFileType()" type="file"></p>
                     <p class="gray mt5">允许类型: jpg，jpeg，gif，png(文件大小不得大于2M)<span id="fileTypeError" style="display: none;"><font color="red">请选择正确的文件类型</font></span></p>
				</div>
			</td>
		</tr>

		<tr>
			<td>顺序</td>
			<td><input type="text" name="offset" class="input input_wd"></td>
		</tr>
	</tbody>
</table>
<div class="tac mt5 mb10">
<input type="hidden" name="hid" value="$hid">
<input type="hidden" name="model" value="$model">
<input type="hidden" name="type" value="add">
<input type="hidden" name="step" value="2">
<span class="btn2"><span><button type="button" name="ajaxsubmit" onclick="ajax.submit(this.form,ajax.guide);" onfocus="blur();">提交</button></span></span>
</div>
</form>
<!--
EOT;
}else{print <<<EOT
-->
<form action="$ajax_basename" method="post" name="form1" onsubmit="return false;" enctype="multipart/form-data">
<table cellspacing="0" cellpadding="0" width="500">
	<tbody>
		<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>编辑内容</th></tr>

		<tr>
			<td>标题</td>
			<td>
				<input type="text" class="input input_wb" size="40" name="title" maxlength="3" value="$push[title]">
				
			</td>
		</tr>
		<tr>
			<td>链接地址</td>
			<td>
				<input type="text" class="input input_wb" size="40" name="url" value="$push[url]" >
			</td>
		</tr>
		<tr>
			<td>图片地址</td>
			<td>
				<style type="text/css">
				.imgListA_pw{padding-bottom:10px;}
				.imgListA_pw li{float:left;width:60px;margin-right:20px; text-align:center;}
				.imgListA_pw li{border:1px solid #fff;cursor:pointer;height:60px;width:60px;}
				.imgListA_pw li:hover{border:1px solid #98ba2a;}
				.imgListA_pw .current{cursor:pointer; position:relative;}
				.imgListA_pw .current div{width:60px;height:60px;background: url(apps/stopic/image/group-current.gif) no-repeat; position:absolute;}
				</style>
				
				<div class="cc mb10">
					<ul id="imagetype_ul" class="list_A list_80">
                        <li><span id="imagetype_upload"><input onclick="getObj('imagetype_input_div').style.display='none';getObj('imagetype_upload_div').style.display='';" name="select_imagetype" value="1" type="radio">图片上传</span></li>
                        <li><span id="imagetype_input"><input onclick="getObj('imagetype_input_div').style.display='';getObj('imagetype_upload_div').style.display='none';" checked="checked" name="select_imagetype" value="2" type="radio">图片链接</span></li>
                    </ul>
				</div>
				<div id="imagetype_input_div" style="display:">
					<div style="background:#F7F7F7; border: 1px solid #ccc; width: 40px; height: 40px;" class="fl mr10">
						<img src="$push[image]" width="40" height="40">
					</div>
					<input id="image" name="image" value="$push[image]" size="40" class="input" type="text">
				</div>
				<div id="imagetype_upload_div" style="display:none">
					<p><input id="uploadpic" name="uploadpic" onchange="checkFileType()" type="file"></p>
                    <p class="gray mt5">允许类型: jpg，jpeg，gif，png(文件大小不得大于2M)<span id="fileTypeError" style="display: none;"><font color="red">请选择正确的文件类型</font></span></p>
				</div>
				<script language="JavaScript" src="mode/area/js/imagetype.js"></script>
				<script language="javascript">
				window.onload = function(){
					var imageTypeImp = New(imageType,['imagetype_ul']);
				}
				</script>
				
			</td>
        </tr>
		<tr>
			<td>顺序</td>
			<td><input type="text" name="offset" class="input input_wd" value="$push[offset]"></td>
		</tr>
	</tbody>
</table>

<div class="tac mt5 mb10">
<input type="hidden" name="hid" value="$hid">
<input type="hidden" name="id" value="$id">
<input type="hidden" name="model" value="$model">
<input type="hidden" name="type" value="edit">
<input type="hidden" name="step" value="2">
<span class="btn2"><span><button type="button" name="ajaxsubmit" onclick="ajax.submit(this.form,ajax.guide);" onfocus="blur();">提交</button></span></span>
</div>
</form>
<!--
EOT;
}?>-->